home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Ahoy 1989 February
/
Ahoy_Magazine_89-02_1989_Double_L.d64
/
Moveable Loader
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-10-26
|
2KB
|
68 lines
100 print"[147]*** moveable dos wedge ***"
110 print" choose location.":print
120 print,"1[146] normal (52224)":print,"2[146] top of basic"
130 print,"3[146] other":print
140 poke198,0:wait198,1:getk$:k=val(k$)
150 onkgoto200,220,260
160 goto140
170 hb=int(ad/256):lb=ad-256*hb:return
180 print"illegal address":end
190 rem *** normal ***
200 ds=52224:ad=ds:gosub170:goto300
210 rem *** top of basic ***
220 poke56,peek(56)-4:clr
230 lb=peek(55):hb=peek(56):ds=lb+256*hb
240 goto300
250 rem *** other ***
260 input" where";ds
270 ifds<1024ords>39936andds<49152ords>52224then180
280 ad=ds:gosub170
290 rem *** all purpose bload ***
300 f$="dos 5.1":sa=0
310 print" loading "f$
320 sys57812f$,8,sa
330 poke780,0:poke781,lb:poke782,hb
340 sys65493:rem call kernal load
350 rem *** new data ***
360 fori=0to98:readd:pokeds+123+i,d:next
370 pokeds+577,39
380 rem *** relocate ***
390 reada1,d1:ifa1=-1then430
400 ad=ds+d1:gosub170
410 pokeds+a1,lb:pokeds+a1+1,hb
420 goto390
430 fori=0to10:reada2:ad=ds+a2:gosub170
440 pokeds+3+i,hb:pokeds+14+i,lb:next
450 ad=ds+39:gosub170:pokeds+307,lb:pokeds+311,hb
460 ad=ds+40:gosub170:pokeds+359,lb:pokeds+363,hb
470 sysds:print" installed"ds"to"ds+857:new
480 rem *** new data ***
490 data13,13,68,79,83,32,77,65
500 data78,65,71,69,82,32,86,53
510 data46,49,47,48,55,49,51,56
520 data50,32,66,89,32,66,46,32
530 data70,65,73,82,66,65,73,82
540 data78,13,40,67,41,32,67,79
550 data77,77,79,68,79,82,69,13
560 data13,0,78,13,13,40,67,41
570 data32,49,57,169,13,32,22,231
580 data76,144,205,160,255,32,179,238
590 data32,179,238,136,208,247,76,121
600 data0,0,166,58,232,208,247,76
610 data123,227,0
620 rem *** relocate absolutes ***
630 data1,225,228,222,238,119,241,843
640 data275,25,299,122,302,675,315,119
650 data320,3,324,14,334,25,339,39
660 data347,39,354,369,367,319,384,39
670 data398,431,423,412,533,457,551,122
680 data572,122,593,122,637,190,642,39
690 data647,119,653,39,661,119,670,119
700 data684,826,759,39,762,121,774,120
710 data790,121,808,39,815,120,846,123
720 data544,198,618,213,223,243,196,400
730 data-1,-1
740 rem *** vectors ***
750 data545,545,545,545,545,632,327,327
760 data327,638,619